package watercups.operators;

import templates.Operator;
import watercups.states.WaterCupState;

public class Empty2 implements Operator<WaterCupState>{

	public int getOperatorNumber(){
		return 4;
	}
	
	public boolean available(WaterCupState s){
		if(s.getCapacity2()>0)
			return true;
		else
			return false;
	}
	
	public WaterCupState execute(WaterCupState s){
		return new WaterCupState(s.getCapacity1(),0);
	}
	
	public String toString(){
		return "Emptying the second cup";
	}
}
